package com.newy.domain.sys.vo;

import java.util.Date;

import javax.servlet.http.HttpSession;

/**
 * 当前登陆用户信息类，用于登陆用户管理功能
 * @author linzongxue
 * @create_date 2011-12-26
 */
public class CurrentLoginInfo {
	private long userId;
	private String loginName;
	private String userName;
	private String departName;
	private String ipAddress;
	private Date loginTime;
	private String browser;
	private String sessionId;
	private HttpSession session;
	public long getUserId() {
		return userId;
	}
	public void setUserId(long userId) {
		this.userId = userId;
	}
	public String getLoginName() {
		return loginName;
	}
	public void setLoginName(String loginName) {
		this.loginName = loginName;
	}
	public String getUserName() {
		return userName;
	}
	public void setUserName(String userName) {
		this.userName = userName;
	}
	public String getDepartName() {
		return departName;
	}
	public void setDepartName(String departName) {
		this.departName = departName;
	}
	public String getIpAddress() {
		return ipAddress;
	}
	public void setIpAddress(String ipAddress) {
		this.ipAddress = ipAddress;
	}
	public Date getLoginTime() {
		return loginTime;
	}
	public void setLoginTime(Date loginTime) {
		this.loginTime = loginTime;
	}
	public String getBrowser() {
		return browser;
	}
	public void setBrowser(String browser) {
		this.browser = browser;
	}
	public String getSessionId() {
		return sessionId;
	}
	public void setSessionId(String sessionId) {
		this.sessionId = sessionId;
	}
	public HttpSession getSession() {
		return session;
	}
	public void setSession(HttpSession session) {
		this.session = session;
	}
	@Override
	public boolean equals(Object obj) {
		if (obj == null || !(obj instanceof CurrentLoginInfo)){
			return false;
		}
		return this.getSessionId().equals(((CurrentLoginInfo)obj).getSessionId());
	}
}
